import {Injectable} from '@angular/core';
import {Observable} from 'rxjs/Observable';
import {HttpService} from 'itcloud-plugin';

@Injectable()
export class DemoInterface {
    constructor(private http: HttpService) {
    }

    // get获取demo数据
    getDemoDataByGet(search) {
        return this.http.getData({
            url: '/webui/home/getUserInfo',
            search: search
        });
    }
    // post获取demo数据
    getDemoDataByPost(data) {
        return this.http.postData({
            url: '/webui/home/getUserInfo',
            data: data
        });
    }
}
